package com.example.AIstudy.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.annotation.JsonProperty;
import io.swagger.models.auth.In;
import lombok.Data;

import java.io.Serializable;
import java.sql.Timestamp;
import java.util.List;
import java.util.Map;

@Data
@TableName("cuotiji")
public class CuoTiJi implements Serializable {
    //自增的主键
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @TableField("stuID")
    private Integer stuID;
    //题目的类别
    @TableField("category")
    private String category;

    //题目的问题
    @TableField("problem")
    private String problem;

    //题目的领域
    @TableField("field")
    private String field;

    //题目的答案
    @TableField("answer")
    private String answer;

    //这个题目的同道题（相当于子题）
    @TableField("sonProID")
    private String sonProID;

    //这个题目是不是单独的题目
    @TableField("isSingle")
    private boolean isSingle;

    @TableField("insertTime")
    private Timestamp insertTime;

    //这个题目是不是单独的题目
    @TableField("score")
    private int score=0;

    //选择题的选项个数
    @TableField("choiceNum")
    private int choiceNum;

    //难度等级
    @TableField("level")
    private int level;

    //难度等级
    @TableField(value="knowledgeIDs")
    private String knowledgeIDs;

    //选项1
    @TableField("choice1")
    private String choice1;
    //选项2
    @TableField("choice2")
    private String choice2;
    //选项3
    @TableField("choice3")
    private String choice3;
    //选项4
    @TableField("choice4")
    private String choice4;

    //题干内容
    @TableField("content")
    private String content;

//    //封装子习题
//    @TableField(exist = false)
//    List<Exercise> sonExercise;

    //嵌入
    @TableField("esID")
    private String esID;

    //学生的答案
    @TableField("stuAnswer")
    public String stuAnswer;

    //选择题正误
    @TableField("isRight")
    public boolean isRight;

    //作文评语对应的id
    @TableField("compCommentID")
    public Integer compCommentID=null;

    //翻译评语对应的id
    @TableField("transCommentID")
    public Integer transCommentID=null;

    //翻译题对应的得分详情
    @TableField(exist = false)
    public TranslateDetail translateDetail;

    //作文对应的得分详情
    @TableField(exist = false)
    public CompositionDetail compositionDetail;

    //得分
    @TableField("stuScore")
    public int stuScore=0;

    @TableField("falseReasonID")
    public Integer falseReasonID;

    @TableField(exist = false)
    public String falseReason;

    @TableField("aiComment")
    public String aiComment;

    @TableField(exist = false)
    public List<CuoTiJi> cuoTiList;

    //为了封装方便
    @TableField(exist = false)
    List<Exercise>sonExercise;

    @TableField("userComment")
    public String userComment;

    //已经巩固的次数
    @TableField("redoNum")
    public Integer redoNum;

    //巩固记录的ID，为了封装方便
    @TableField(exist = false)
    public Integer redoID;

    //今天需要巩固
    @TableField("needRedo")
    public Boolean needRedo;

//    @TableField(exist = false)
//    public Map<String,String> tags;
}
